﻿<%@ Page Language="C#" AutoEventWireup="True" CodeBehind="ControlList.aspx.cs" Inherits="Medianamik.UI.ConfigManagement.ControlList"
    MasterPageFile="/Medianamik/MasterPages/MedianamikModule.Master" %>

<asp:Content ID="ContextMenuContent" ContentPlaceHolderID="ContextMenu" runat="server">
    <asp:HyperLink ID="lnkAddControl" runat="server" class="Action BtAjouter" NavigateUrl="controlmanagement.aspx" Text="<%$ Resources: Medianamik_ConfigurationManagement, AddControl %>" />
</asp:Content>
<asp:Content ID="CenterContent" ContentPlaceHolderID="CenterContent" runat="server">
    <lock:LockInfoTooltip runat="server" id="LockInfoTooltip" OnLockDeleted="LockInfoTooltip_LockDeleted" />
    <telerik:RadGrid runat="server" ID="grdControls" EnableEmbeddedSkins="false" Skin="Medianamik"
        AllowPaging="false" AutoGenerateColumns="false" OnDeleteCommand="grdControls_DeleteCommand"
        OnNeedDataSource="grdControls_NeedDataSource" AllowMultiRowSelection="false" Width="100%">
        <MasterTableView DataKeyNames="ID">
            <Columns>
                <telerik:GridBoundColumn DataField="Name" />
                <telerik:GridTemplateColumn HeaderStyle-Width="1%" HeaderText="Actions">
                    <HeaderStyle HorizontalAlign="Center" />
                    <ItemStyle CssClass="Actions" />
                    <ItemTemplate>
                        <table border="0" cellpadding="0" cellspacing="0" align="center">
                            <tr>
                                <td><med:EditLink Enabled="true" runat="server" NavigateUrl='<%# "controlmanagement.aspx?id=" + Eval("ID").ToString() %>'
                                        ObjectId='<%# Eval("ID") %>' OnRequestFailed="LockLink_RequestFailed" /></td>
                                <td><med:ConfirmedDeleteButton ID="btnDeleteControl" CommandArgument='<%# Eval("ID") %>'
                                        CommandName="Delete" runat="server" ConfirmText="<%$ Resources: Medianamik_ConfigurationManagement, ConfirmDeleteControl %>" /></td>
                            </tr>
                        </table>
                    </ItemTemplate>
                </telerik:GridTemplateColumn>
            </Columns>
            <NoRecordsTemplate>
			    <asp:Literal ID="NoRecords" runat="server" Text="<%$ Resources: Medianamik_ContentManagement, NoRecordsToDisplay %>" />
			</NoRecordsTemplate>
        </MasterTableView>
    </telerik:RadGrid>
</asp:Content>
